package com.sf.fy.uav.controller;

import com.sf.fy.uav.entity.CouponActivityRecord;
import com.sf.fy.uav.service.ICouponActivityRecordService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.stereotype.Controller;

import java.util.List;

/**
 * <p>
 * 订单商品关联表 前端控制器
 * </p>
 *
 * @author LTQ
 * @since 2024-08-27
 */
@Controller
@RequestMapping("/applet/couponActivityRecord")
public class CouponActivityRecordController {

    @Autowired
    private ICouponActivityRecordService couponActivityRecordService;


    public Long getRecordCnt(String couponActivityId, String userId) {
        return couponActivityRecordService.getRecordCnt(couponActivityId, userId);
    }

    public List<CouponActivityRecord> getNewerRecord(String userId) {
        return couponActivityRecordService.getNewerRecord(userId);
    }


    public List<CouponActivityRecord> selByCouponActivityIds(List<String> couponActivityIds, Integer page, Integer size) {
        return couponActivityRecordService.selByCouponActivityIds(couponActivityIds, page, size);
    }

    public Long countByCouponActivityIds(List<String> couponActivityIds) {
        return couponActivityRecordService.countByCouponActivityIds(couponActivityIds);
    }

}
